package bist.believeinstep.mapper;

import java.sql.ResultSet;
import java.sql.SQLException;

import org.springframework.jdbc.core.RowMapper;

import bist.believeinstep.domain.RestaurantHotelImage;

public class RestaurantHotelImageMapper implements RowMapper<RestaurantHotelImage>{
	public RestaurantHotelImage mapRow(ResultSet rs, int rowNum) throws SQLException{
		RestaurantHotelImage resHotelImage = new RestaurantHotelImage();
		
		resHotelImage.setId(rs.getInt("id"));
		resHotelImage.setRestaurantHotelId(rs.getInt("bist_restaurant_hotels_id"));
		resHotelImage.setImageId(rs.getInt("bist_images_id"));
		resHotelImage.setCreated(rs.getTimestamp("created_date"));
		resHotelImage.setModified(rs.getTimestamp("modified_date"));
		resHotelImage.setCreatedBy(rs.getString("created_by"));
		resHotelImage.setModifiedBy(rs.getString("modified_by"));
		
		return resHotelImage;
	}
}
